#region head comment
/*
Code generate by YhdSdkTool.
email:starpeng@vip.qq.com
2013-01-21 23:00:57:780 +08:00
*/
#endregion

using System;
using System.Xml.Serialization;
using System.Collections.Generic;
using YhdSdk.Domain;
using YhdSdk.Domain.Group;
using YhdSdk.Response.Group;

namespace YhdSdk.Request.Group
{
    /// <summary>
    /// 团购订单信息确认
    ///<para></para>
    ///<para>合作方订单生成后，将订单信息回传给1号商城平台，1号商城平台接收成功，则返回成功记录数。失败，则返回失败记录数，及相应的错误信息描述。</para>
    /// </summary>
    public class YhdGroupBuyOrderVerifyRequest : IYhdRequest<YhdGroupBuyOrderVerifyResponse>
    {
        /// <summary>
        /// 1号商城订单号码
        /// </summary>
        [XmlElement("orderCode")]
        public String OrderCode
        {
            get;
            set;
        }

        /// <summary>
        /// 合作方订单号码
        /// </summary>
        [XmlElement("partnerOrderCode")]
        public String PartnerOrderCode
        {
            get;
            set;
        }

        /// <summary>
        /// 订单金额
        /// </summary>
        [XmlElement("orderAmount")]
        public Double OrderAmount
        {
            get;
            set;
        }

        /// <summary>
        /// 订单生成时间格式：yyyy-MM-dd HH:mm:ss
        /// </summary>
        /// <example>2011-12-12 20:10:10</example>
        [XmlElement("orderCreateTime")]
        public String OrderCreateTime
        {
            get;
            set;
        }

        /// <summary>
        /// Api接口名称
        /// </summary>
        public String ApiName
        {
            get{ return "yhd.group.buy.order.verify"; }
        }

        /// <summary>
        /// 获取参数列表
        /// </summary>
        public IDictionary<string, string> GetParameters()
        {
            YhdDictionary parameters = new YhdDictionary();
            parameters.Add("orderCode" ,this.OrderCode);
            parameters.Add("partnerOrderCode" ,this.PartnerOrderCode);
            parameters.Add("orderAmount" ,this.OrderAmount);
            parameters.Add("orderCreateTime" ,this.OrderCreateTime);
            return parameters;
        }

        /// <summary>
        /// 验证参数
        /// </summary>
        public void Validate()
        {
            RequestValidator.ValidateRequired("orderCode", this.OrderCode);
            RequestValidator.ValidateRequired("partnerOrderCode", this.PartnerOrderCode);
            RequestValidator.ValidateRequired("orderAmount", this.OrderAmount);
            RequestValidator.ValidateRequired("orderCreateTime", this.OrderCreateTime);
        }

    }
}
